package com.netease.framework.a;

import android.net.Uri;
import com.netease.c.p;
import com.netease.pris.a.e;
import com.netease.pris.a.r;
import java.io.ByteArrayInputStream;
import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.net.URLEncoder;
import java.util.Iterator;
import java.util.LinkedList;
import java.util.List;
import org.apache.http.HttpEntity;
import org.apache.http.HttpResponse;

public class m
  implements p
{
  private static int a = 0;
  private static final int b = 1;
  private static final int c = 2;
  private static final int d = 4;
  private static final int e = 8;
  private static final int f = 16;
  private static final int g = 32;
  private static final int h = 64;
  private static final int i = 128;
  public static final int j = 1;
  public static final int k = 2;
  public static final int l = 2;
  int A;
  int B;
  String C;
  String D;
  int E;
  com.netease.i.c F;
  int m;
  b n;
  String o;
  String p;
  HttpEntity q;
  c r;
  List s;
  List t;
  long u;
  int v;
  int w;
  int x;
  int y;
  String z;

  public m(String paramString)
  {
    this(paramString, b.a);
  }

  public m(String paramString, b paramb)
  {
    if ((paramString == null) || (paramString.length() == 0))
      throw new IllegalArgumentException("url");
    this.n = paramb;
    this.o = paramString;
    this.p = paramString;
    this.m = C();
  }

  /** @deprecated */
  public static int C()
  {
    monitorenter;
    try
    {
      if (a >= 32767)
        a = 0;
      int i1 = 1 + a;
      a = i1;
      monitorexit;
      return i1;
    }
    finally
    {
      localObject = finally;
      monitorexit;
    }
    throw localObject;
  }

  private void a(int paramInt, boolean paramBoolean)
  {
    if (paramBoolean)
      this.B = (paramInt | this.B);
    while (true)
    {
      return;
      this.B &= (paramInt ^ 0xFFFFFFFF);
    }
  }

  private boolean a(int paramInt)
  {
    if ((paramInt & this.B) != 0);
    for (int i1 = 1; ; i1 = 0)
      return i1;
  }

  public boolean A()
  {
    return a(128);
  }

  public boolean B()
  {
    return a(64);
  }

  public com.netease.i.c D()
  {
    return this.F;
  }

  public h a(HttpResponse paramHttpResponse)
  {
    return null;
  }

  public void a()
  {
    if (this.t != null)
    {
      StringBuilder localStringBuilder = new StringBuilder(this.o);
      if (this.t.size() > 0)
      {
        localStringBuilder.append('?');
        Iterator localIterator = this.t.iterator();
        while (localIterator.hasNext())
        {
          h localh = (h)localIterator.next();
          localStringBuilder.append(URLEncoder.encode(localh.a())).append('=').append(URLEncoder.encode(localh.b())).append('&');
        }
        localStringBuilder.deleteCharAt(-1 + localStringBuilder.length());
      }
      this.p = localStringBuilder.toString();
    }
  }

  public void a(c paramc)
  {
    this.r = paramc;
  }

  public void a(com.netease.i.c paramc)
  {
    this.F = paramc;
  }

  public void a(String paramString)
  {
    this.z = paramString;
  }

  public void a(String paramString1, String paramString2)
  {
    if ((paramString1 == null) || (paramString2 == null));
    while (true)
    {
      return;
      if (this.t == null)
        this.t = new LinkedList();
      this.t.add(new h(paramString1, paramString2));
    }
  }

  public void a(HttpEntity paramHttpEntity)
  {
    this.q = paramHttpEntity;
  }

  public boolean a(Object paramObject)
  {
    int i1 = 0;
    if ((e()) && (paramObject != null) && ((paramObject instanceof m)))
    {
      m localm = (m)paramObject;
      if ((localm.e()) && (this.A == localm.A) && (B() == localm.B()) && (o() == localm.o()) && (j() == localm.j()) && (b().equals(localm.b())) && (l().equals(localm.l())))
        i1 = 1;
    }
    return i1;
  }

  public String b()
  {
    return this.p;
  }

  public void b(int paramInt)
  {
    this.v = paramInt;
  }

  public void b(String paramString)
  {
    this.D = paramString;
  }

  public void b(String paramString1, String paramString2)
  {
    if ((paramString1 == null) || (paramString1.length() == 0) || (paramString2 == null));
    while (true)
    {
      return;
      if (this.s == null)
        this.s = new LinkedList();
      this.s.add(new h(paramString1, paramString2));
    }
  }

  public void c(int paramInt)
  {
    this.E = paramInt;
  }

  public void c(boolean paramBoolean)
  {
    a(2, paramBoolean);
  }

  public void d(int paramInt)
  {
    this.y = paramInt;
  }

  public void d(boolean paramBoolean)
  {
    a(16, paramBoolean);
  }

  public boolean d()
  {
    return false;
  }

  public void e(int paramInt)
  {
    this.A = paramInt;
  }

  public void e(boolean paramBoolean)
  {
    a(8, paramBoolean);
  }

  public boolean e()
  {
    return a(2);
  }

  public int f()
  {
    return this.v;
  }

  public void f(int paramInt)
  {
    this.w = paramInt;
  }

  public void f(boolean paramBoolean)
  {
    a(4, paramBoolean);
  }

  public int g()
  {
    return this.w;
  }

  public void g(boolean paramBoolean)
  {
    a(32, paramBoolean);
  }

  public int h()
  {
    return this.E;
  }

  public void h(boolean paramBoolean)
  {
    a(128, paramBoolean);
  }

  public int i()
  {
    return this.m;
  }

  public void i(boolean paramBoolean)
  {
    a(64, paramBoolean);
  }

  public int j()
  {
    return this.y;
  }

  protected List k()
  {
    return this.t;
  }

  protected String l()
  {
    if (this.z == null);
    for (String str = ""; ; str = this.z)
      return str;
  }

  public c m()
  {
    return this.r;
  }

  public String n()
  {
    return Uri.parse(this.o).getHost();
  }

  public b o()
  {
    return this.n;
  }

  public HttpEntity p()
  {
    return this.q;
  }

  public long q()
  {
    return this.u;
  }

  public void r()
  {
    a(1, true);
  }

  public List s()
  {
    return this.s;
  }

  public String t()
  {
    return this.D;
  }

  public boolean u()
  {
    return a(1);
  }

  public String v()
  {
    Object localObject;
    if ((w()) && (this.C == null))
    {
      localObject = null;
      switch (f.a[o().ordinal()])
      {
      default:
      case 1:
      case 2:
      case 3:
      case 4:
      case 5:
      case 6:
      }
    }
    while (true)
    {
      this.C = ((String)localObject);
      return this.C;
      localObject = r.a(b() + l());
      continue;
      try
      {
        ByteArrayOutputStream localByteArrayOutputStream = new ByteArrayOutputStream();
        if (this.q != null)
          this.q.writeTo(localByteArrayOutputStream);
        localByteArrayOutputStream.close();
        ByteArrayInputStream localByteArrayInputStream = new ByteArrayInputStream(localByteArrayOutputStream.toByteArray());
        String str = r.a(b() + l() + e.a(localByteArrayInputStream));
        localObject = str;
      }
      catch (IOException localIOException)
      {
        localObject = r.a(b() + l() + localIOException.hashCode());
      }
    }
  }

  public boolean w()
  {
    return a(16);
  }

  public boolean x()
  {
    return a(8);
  }

  public boolean y()
  {
    return a(4);
  }

  public boolean z()
  {
    return a(32);
  }
}

/* Location:           D:\android\hack\dex2jar-0.0.9.8\classes_dex2jar.jar
 * Qualified Name:     com.netease.framework.a.m
 * JD-Core Version:    0.6.0
 */